#!/usr/bin/python3

import urllib.parse
import httplib2

http = httplib2.Http()

url = 'http://www.125home.cn/user/doLogin'
body = {'email': 'shiyusen11@163.com', 'password': '123456'}
headers = {'Content-type': 'application/x-www-form-urlencoded'}

response, content = http.request(url, 'POST', headers=headers, body=urllib.parse.urlencode(body))

headers = {'Cookie': response['set-cookie']}

# url = 'http://www.example.com/home'
# response, content = http.request(url, 'GET', headers=headers)